import React from 'react'
import {BrowserRouter as Router, Route ,Link ,Routes} from 'react-router-dom'
import Index from './Pages/index'
import List from './Pages/List'
import Home from './Pages/home'

function AppRouter(){
return(
    <Router>
            <ul>
                <li><Link to="/">首页</Link></li>
                <li><Link to="/list/">列表</Link></li>
            </ul>
    <Routes>    
    <Route path="/" element={<Index />} />
    <Route path="/list/:id"  element={<List />} />
    <Route path="/home"  element={<Home/>} />
    </Routes> 
    </Router>
)

}

export default AppRouter 